package org.yzh.protocol.commons.transform.attribute;

import io.github.yezhihao.protostar.annotation.Field;
import org.yzh.protocol.hlj.ObdExtra;

import java.time.LocalDateTime;

/**
 * 0x42 车辆运行状态（黑）
 */
public class HljVos0x42 {

    public static final int key = 66;

    @Field(length = 4, desc = "纬度")
    private int latitude;

    @Field(length = 4, desc = "经度")
    private int longitude;

    @Field(length = 2, desc = "卫星高程")
    private int altitude;

    @Field(length = 2, desc = "卫星速度(1/10公里每小时)")
    private int wSpeed;

    @Field(length = 2, desc = "卫星方向")
    private int direction;

    @Field(length = 2, desc = "原车速度(1/10公里每小时)")
    private int vSpeed;
    //    时间
    @Field(length = 6, charset = "BCD", desc = "时间(YY-MM-DD-hh-mm-ss（GMT+8 时间）)")
    private LocalDateTime dateTime;
    //
    @Field(length = 2, desc = "X 轴加速度,以 g 为单位乘以 10 的 2 次方，精确到百分之一 g")
    private int xSpeed;

    @Field(length = 2, desc = "Y 轴加速度,以 g 为单位乘以 10 的 2 次方，精确到百分之一 g")
    private int ySpeed;

    @Field(length = 2, desc = "Z 轴加速度,以 g 为单位乘以 10 的 2 次方，精确到百分之一 g")
    private int zSpeed;

    @Field(length = 2, desc = "X 轴角速度,以度每秒为单位乘以 10 的 2 次方，精确到百分之一度每 秒")
    private int xAngleSpeed;

    @Field(length = 2, desc = "Y 轴角速度,以度每秒为单位乘以 10 的 2 次方，精确到百分之一度每 秒")
    private int yAngleSpeed;

    @Field(length = 2, desc = "Z 轴角速度,以度每秒为单位乘以 10 的 2 次方，精确到百分之一度每 秒")
    private int zAngleSpeed;

    @Field(length = 1, desc = "制动状态: 0x00 ：无制动； 0x01 ：制动")
    private int brakingStatus;

    @Field(length = 1, desc = "转向灯状态：0x00 ：未开方向灯； 0x01 ：左转方向灯； 0x02 ：右转方向灯")
    private int turnSignalStatus;

    @Field(length = 1, desc = "远光状态：0x00 ：远光灯关； 0x01 ：远光灯开")
    private int hBeamStatus;

    @Field(length = 1, desc = "近光状态：0x00 ：近光灯关； 0x01 ：近光灯开")
    private int lBeamStatus;

    @Field(length = 14, desc = "扩展 OBD 车辆状态，定义见表 3 无法获取填充 0")
    private ObdExtra obdExtra;


    public int getLatitude() {
        return latitude;
    }

    public void setLatitude(int latitude) {
        this.latitude = latitude;
    }

    public int getLongitude() {
        return longitude;
    }

    public void setLongitude(int longitude) {
        this.longitude = longitude;
    }

    public int getAltitude() {
        return altitude;
    }

    public void setAltitude(int altitude) {
        this.altitude = altitude;
    }

    public int getwSpeed() {
        return wSpeed;
    }

    public void setwSpeed(int wSpeed) {
        this.wSpeed = wSpeed;
    }

    public int getDirection() {
        return direction;
    }

    public void setDirection(int direction) {
        this.direction = direction;
    }

    public int getvSpeed() {
        return vSpeed;
    }

    public void setvSpeed(int vSpeed) {
        this.vSpeed = vSpeed;
    }

    public LocalDateTime getDateTime() {
        return dateTime;
    }

    public void setDateTime(LocalDateTime dateTime) {
        this.dateTime = dateTime;
    }

    public int getxSpeed() {
        return xSpeed;
    }

    public void setxSpeed(int xSpeed) {
        this.xSpeed = xSpeed;
    }

    public int getySpeed() {
        return ySpeed;
    }

    public void setySpeed(int ySpeed) {
        this.ySpeed = ySpeed;
    }

    public int getzSpeed() {
        return zSpeed;
    }

    public void setzSpeed(int zSpeed) {
        this.zSpeed = zSpeed;
    }

    public int getxAngleSpeed() {
        return xAngleSpeed;
    }

    public void setxAngleSpeed(int xAngleSpeed) {
        this.xAngleSpeed = xAngleSpeed;
    }

    public int getyAngleSpeed() {
        return yAngleSpeed;
    }

    public void setyAngleSpeed(int yAngleSpeed) {
        this.yAngleSpeed = yAngleSpeed;
    }

    public int getzAngleSpeed() {
        return zAngleSpeed;
    }

    public void setzAngleSpeed(int zAngleSpeed) {
        this.zAngleSpeed = zAngleSpeed;
    }

    public int getBrakingStatus() {
        return brakingStatus;
    }

    public void setBrakingStatus(int brakingStatus) {
        this.brakingStatus = brakingStatus;
    }

    public int getTurnSignalStatus() {
        return turnSignalStatus;
    }

    public void setTurnSignalStatus(int turnSignalStatus) {
        this.turnSignalStatus = turnSignalStatus;
    }

    public int gethBeamStatus() {
        return hBeamStatus;
    }

    public void sethBeamStatus(int hBeamStatus) {
        this.hBeamStatus = hBeamStatus;
    }

    public int getlBeamStatus() {
        return lBeamStatus;
    }

    public void setlBeamStatus(int lBeamStatus) {
        this.lBeamStatus = lBeamStatus;
    }

    public ObdExtra getObdExtra() {
        return obdExtra;
    }

    public void setObdExtra(ObdExtra obdExtra) {
        this.obdExtra = obdExtra;
    }
}